define([
  'utils/Conf',
  'models/Content',
  'collections/Collection'
], function(Conf, Content, Collection){
  var Contents = Collection.extend({
    model: Content,

    initialize: function(models, options) {
      options || (options = {});
      Collection.prototype.initialize.call(this, models, options);

      if(options.type === "photo") {
        this.type = "photo";
      }
      if(options.owned) {
        this.owned = options.owned;
      }
    },

    fetch: function(options) {
      options || (options = {});
      options.data || (options.data = {});
      if(this.owned) {
        options.data.owned = this.owned;
      } else {
        options.data.owned = false;
      }
      
      Collection.prototype.fetch.call(this, options);
    },
    
    url: function() {
      if(this.type === "photo") {
        return Conf.routes.users.photos;
      }
    }
  });

  return Contents;
});